<link rel="stylesheet" href="css/agcfs.pub.css">
<nav class="navbar navbar-default" role="navigation">
    <div class="container-fluid">
        <div class="navbar-header">
            <a class="navbar-brand" href="#">会计年度</a>
        </div>
    </div>
    <div class="navbar-form navbar-left" role="search">
        <select id="selectNd" class="form-control" data-bind="event:{change:getItemData}"></select>
        <div class="btn-group" role="group" aria-label="...">
            <button id="btnInsert" class="btn btn-primary"  data-bind="click: addReportItem">新增</button>
            <button id="btnUpdate" class="btn btn-primary"  data-bind="click: editReportItem">编辑</button>
            <button id="btnDelete" class="btn btn-primary"  data-bind="click: delReportItem">删除</button>
        </div>
    </div>
</nav>

<div>
    <!--列表数据区-->
    <div type="text" u-meta='{"id":"reportItem-grid","data":"reportItemDataTable","type":"grid","editType":"default","editable":false,"autoExpand":false,"showTree":false}'>
        <div options='{"field":"nd","dataType":"String","title":"年度","editType":"string","width": 90}'></div>
        <div options='{"field":"reportItemCode","dataType":"String","title":"报表项代码","editType":"string","width": 140}'></div>
        <div options='{"field":"reportItemName","dataType":"String","title":"报表项名称","editType":"string","width": 200}'></div>
        <div options='{"field":"pitemCode","dataType":"String","title":"父代码","editType":"string","width": 140}'></div>
        <div options='{"field":"reportItemType","dataType":"String","title":"类型","editOptions":{"id":"combobox2","type":"combo","mutil":false,"onlySelect": true,"datasource":"combItemType"},"editType":"combo","renderType":"comboRender","width": 160}'></div>
        <div options='{"field":"balDir","dataType":"String","title":"余额方向","editOptions":{"id":"radio", "type":"radio","datasource":"radioDir"},"editType":"radio","renderType":"radioRender","width": 160}'></div>
        <div options='{"field":"remark","dataType":"String","title":"备注","editType":"string","width": 200}'></div>
    </div>
</div>

<!--删除一个报表项提示-->
<div class="modal fade" id="delete-reportItem-notice" tabindex="-1" role="dialog" aria-hidden="true">
    <div class="modal-dialog infomodal" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                <h4 class="modal-title">提示</h4>
            </div>

            <div class="modal-body">
                <div class="modal-body-delete">
                    <p id="modal-delete-text">您确定要删除吗？</p>
                </div>
            </div>
            <div class="modal-footer">
                <div class="btn-group" role="group" aria-label="...">
                    <button class="btn btn-primary" data-bind="click: delete_reportItem">确定</button>
                    <button class="btn btn-primary" data-bind="click: delete_reportItem_close">取消</button>
                </div>
            </div>
        </div>
    </div>
</div>

<!--一个报表项数据区-->
<div class="modal fade" id="reportItem_edit-notice" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
    <div class="modal-dialog editmodal" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                <h4 class="modal-title">报表项</h4>
            </div>
            <div class="modal-body">
                <form class="form-horizontal" role="form">
                    <div class="input-group">
                        <span class="input-group-addon">&emsp;&emsp;&emsp;&emsp;年度</span>
                        <select id="edit-nd" class="form-control" disabled="disabled"></select>
                    </div>

                    <div class="input-group">
                        <span class="input-group-addon">&emsp;报表项代码</span>
                        <input id="edit-reportItemCode" type="text" class="form-control">
                    </div>

                    <div class="input-group">
                        <span class="input-group-addon">&emsp;报表项名称</span>
                        <input id="edit-reportItemName" type="text" class="form-control">
                    </div>

                    <div class="input-group">
                        <span class="input-group-addon">&emsp;&emsp;&emsp;父代码</span>
                        <input id="edit-pitemCode" type="text" class="form-control">
                    </div>

                    <div class="input-group">
                        <span class="input-group-addon">&emsp;&emsp;&emsp;&emsp;类型</span>
                        <select id="edit-reportItemType" type="text" class="form-control"></select>
                    </div>

                    <div class="input-group">
                        <span class="input-group-addon">&emsp;&emsp;余额方向</span>
                        <input id="edit-balDir-DR" type="radio" name="group1" value="DR" checked="checked">借方
                        <input id="edit-balDir-CR" type="radio" name="group1" value="CR" checked="unchecked">贷方
                    </div>

                    <div class="input-group">
                        <span class="input-group-addon">&emsp;&emsp;&emsp;&emsp;备注</span>
                        <input id="edit-remark" type="text" class="form-control">
                    </div>

                    <input type="hidden" id="edit-id">
                </form>
            </div>

            <div class="modal-footer">
                <span id="warn-text" class="label label-warning warn-span"></span>
                <div class="btn-group" role="group" aria-label="...">
                    <button class="btn btn-primary" data-bind="click: saveReportItemEdit">保存</button>
                    <button class="btn btn-primary" data-bind="click: edit_notice_close">取消</button>
                </div>
            </div>
        </div>
    </div>
</div>

<div id="save-success-new" class="save-success-new"><img src="images/ip/menu/success_p.png" height="" width=""/>保存成功!</div>